
def my_decorator(func):
    def wrapper(*args, **kwargs):
        print("Decorator called")
        return func(*args, **kwargs)

    return wrapper


class MyClass:
    def method1(self):
        print("Method 1 called")

    def method2(self):
        print("Method 2 called")

    def method3(self):
        print("Method 3 called")


def decorate_methods(cls, method_names):
    for name in method_names:
        setattr(cls, name, my_decorator(getattr(cls, name)))
    return cls


MyClass = decorate_methods(MyClass, ["method1", "method2"])

if __name__ == '__main__':
    mc = MyClass()
    mc.method1()
    mc.method2()
    mc.method3()
